<template>
	<view class="song_list_item" :style="{height:height}">
		<view v-if="isTitle" class="to_more animate__animated" hover-class="animate__fadeIn">
			<text>{{title}}</text>
			<text class="iconfont icon-youbian"></text>
		</view>
		<view class="item" v-for="i in 3" :key="i">
			<view class="cover">
				<u-image width="100%" 
				border-radius="6px" 
				height="100%" 
				mode="aspectFit" :src="src">
				</u-image>
			</view>
			<view class="info">
				<view class="name">
					<text>Walk Thru Fire</text>
					<text class="article">-Vicetone/Meron Ryan1555555</text>
				</view>
				<view class="play_btn animate__animated" hover-class="animate__fadeIn">
					<text class="iconfont icon-bofang"></text>
				</view>
				<view class="des"><slot>放描述</slot></view>
			</view>
		</view>
	</view>
</template>

<script>
export default {
	props: {
		isTitle: {
			type: Boolean,
			default: false
		},
		title:{
			type:String,
			default:"这是标题"
		},
		height:{
			type:String,
			default:"auto"
		}
	},
	data() {
		return {
			src: '/static/img/logo.png'
		};
	}
};
</script>

<style lang="scss" scoped>
.song_list_item {
	width: 625rpx;
	display: flex;
	flex-direction: column;
	background-color: #fff;
	box-sizing: border-box;
	border-radius: 10px;
	margin-left: 10px;
	overflow: hidden;
	padding-bottom: 10px;
	.to_more{
		width: 100%;
		text-align: center;
		padding: 10px 0;
		text{
			font-size: 18px;
			font-weight: 600;	
		}
	}
	.item {
		width: 100vw;
		padding: 5px;
		display: flex;
		align-items: center;
		justify-content: flex-start;
		flex-direction: row;
		margin-top: 10px;
		.cover {
			height: 60px;
			width: 60px;
			border: 1px solid #ccc;
			// border-radius: $main-border-radius;
		}
		.info {
			height:60px;
			width: 60%;
			display: flex;
			justify-content: center;
			align-items: flex-start;
			flex-direction: column;
			padding-left: 20.83rpx;
			border-bottom: 1px solid rgb(248, 248, 248);
			position: relative;
			.name {
				width: 80%;
				white-space: nowrap;
				text-overflow: ellipsis;
				overflow: hidden;
				.article{
					padding-left: 10.83rpx;
					font-size: 25.16rpx;
					color: rgba(0,0,0,0.6);
				}
			}
			.des {
			}
			.play_btn{
				position: absolute;
				right: 5.83rpx;
				top: 50%;
				transform: translateY(-50%);
				border: 1px solid #ccc;
				border-radius: 15.33rpx;
				padding: 8.83rpx;
				color: #ccc;
			}
		}
		&:last-child >.info{
			border-bottom: none;
		}
	}

}
</style>
